package com.coder4j.platform.service;

import com.coder4j.platform.entity.BizRefEntity;
import com.coder4j.platform.mapper.BizRefMapper;
import com.coder4j.platform.vo.BizRefVO;
import com.coder4j.starter.web.BaseServiceImpl;
import org.springframework.stereotype.Service;
import org.springframework.beans.BeanUtils;

import lombok.extern.slf4j.Slf4j;

import javax.annotation.Resource;

/**
 * 关系表
 * @author keller
 * @date 2024-12-05 10:46:31
 */
@Service
@Slf4j
public class BizRefService extends BaseServiceImpl<BizRefMapper,BizRefEntity,BizRefVO>  {

    @Resource
    private BizRefMapper mapper;

    @Override
    public BizRefVO entity2Vo(BizRefEntity entity) {
        BizRefVO vo = new BizRefVO();
        BeanUtils.copyProperties(entity,vo);
        return vo;
    }

    @Override
    public BizRefEntity vo2Entity(BizRefVO vo) {
        BizRefEntity entity = new BizRefEntity();
        BeanUtils.copyProperties(vo, entity);
        return entity;
    }
}
